<<<<<<< HEAD ======= >>>>>>> 77298c790997af7699687a8a24f6ecc08ea5a8ef

COVID-19 Vaccinations in the United States: A Study

Project Description

Introduction

Results

This is an R Markdown document. Markdown is a simple formatting syntax for authoring HTML, PDF, and MS Word documents. For example, you can include Bold and Italic and Code text. For more details on using R Markdown see http://rmarkdown.rstudio.com.

You should test out updating your GitHub Pages website:

  • clone your group’s blog project repo in RStudio
  • update “Your Project Title Here” to a new title in the YAML header
  • knit index.Rmd
  • commit and push BOTH the index.Rmd and the index.html files
  • go to https://stat231-s21.github.io/Blog-library-cleanverse/ to see the published test document (this is publicly available!)

Including code and plots

You can embed code as normal, for example:

summary(cars)
##      speed           dist       
##  Min.   : 4.0   Min.   :  2.00  
##  1st Qu.:12.0   1st Qu.: 26.00  
##  Median :15.0   Median : 36.00  
##  Mean   :15.4   Mean   : 42.98  
##  3rd Qu.:19.0   3rd Qu.: 56.00  
##  Max.   :25.0   Max.   :120.00

Let’s clean up the format of that output:

In a study from the 1920s, fifty cars were used to see how the speed of the car and the distance taken to stop were related. Speeds ranged between 4 and 25 mph. Distances taken to stop ranged between 2 and 120 feet, with the middle 50% falling between 26 and 56 feet.

You can also embed plots as normal, for example:

Note that the echo = FALSE parameter was added to the code chunk to prevent printing of the R code that generated the plot.

<<<<<<< HEAD

Comparison: CA and TN

=======

Comparison: CA and TN

# read in and plot ca vax over time
library(tidyverse)
library(dplyr)
library(readxl)
library(scales)
## 
## Attaching package: 'scales'
## The following object is masked from 'package:purrr':
## 
##     discard
## The following object is masked from 'package:readr':
## 
##     col_factor
library(viridis)
## Loading required package: viridisLite
## 
## Attaching package: 'viridis'
## The following object is masked from 'package:scales':
## 
##     viridis_pal
ca_time <- read_csv("/Users/smolea/git/Blog-library-cleanverse/amaya/ca_time.csv") %>%
  filter(race != "Unknown", race != "Other/Multiracial")
## Parsed with column specification:
## cols(
##   race = col_character(),
##   date = col_date(format = ""),
##   count = col_double(),
##   frac = col_double()
## )
ca_tg <- ggplot(ca_time, aes(x = date, y = frac, colour = race)) +
  geom_line() +
  labs(colour = "Race", title = "Proportion of Racial Groups Vaccinated Over Time", 
       subtitle = "California, 2021") +
  xlab("Date") + ylab("Proportion of Racial Group")
ca_tg

# read in and plot tn vax over time 
tn_time <- read_csv("/Users/smolea/git/Blog-library-cleanverse/amaya/tn_time.csv") %>%
  filter(race != "UNKNOWN", race != "OTHER/MULTIRACIAL")
## Parsed with column specification:
## cols(
##   date = col_date(format = ""),
##   race = col_character(),
##   count = col_double(),
##   frac = col_double()
## )
tn_tg <- ggplot(tn_time, aes(x = date, y = frac, colour = race)) +
  geom_line() +
  labs(colour = "Race", title = "Proportion of Racial Groups Vaccinated Over Time", 
       subtitle = "Tennessee, 2021") +
  xlab("Date") + ylab("Proportion of Racial Group")
tn_tg

# read in and plot ca county vaccinations
ca_county <- read_csv("/Users/smolea/git/Blog-library-cleanverse/amaya/ca_county.csv") %>%
  mutate(subregion = tolower(county)) %>%
  select(-county)
## Parsed with column specification:
## cols(
##   administered_date = col_date(format = ""),
##   county = col_character(),
##   total_vax = col_double()
## )
ca_counties <- map_data(map = "county", region = "california")
ca_map <- ca_counties %>%
  left_join(ca_county, by = "subregion")
ggplot(ca_map, aes(x = long, y = lat, group = group, fill = total_vax)) +
  geom_polygon(colour = "white") +
  theme_void() +
  coord_fixed(ratio = 1.3) +
  facet_wrap(~administered_date) +
  labs(fill = "Total Vaccinations") +
  scale_fill_viridis(direction = -1) +
  ggtitle("Vaccinations in California, Spring 2021")

# read in and plot tn county vaccinations
options(scipen = 999)
tn_county <- read_csv("/Users/smolea/git/Blog-library-cleanverse/amaya/tn_county.csv") %>%
  mutate(subregion = tolower(COUNTY)) %>%
  select(-COUNTY)
## Parsed with column specification:
## cols(
##   date = col_date(format = ""),
##   COUNTY = col_character(),
##   total_vax = col_double()
## )
tn_counties <- map_data(map = "county", region = "tennessee")
tn_map <- tn_counties %>%
  left_join(tn_county, by = "subregion") %>%
  na.omit()
ggplot(tn_map, aes(x = long, y = lat, group = group, fill = total_vax)) +
  geom_polygon(colour = "white") +
  theme_void() +
  coord_fixed(ratio = 1.3) +
  facet_wrap(~date) +
  labs(fill = "Total Vaccinations") +
  scale_fill_viridis(direction = -1) +
  ggtitle("Vaccinations in Tennessee, Spring 2021")

>>>>>>> 77298c790997af7699687a8a24f6ecc08ea5a8ef

Bulleted list

You can make a bulleted list like this:

  • item 1
  • item 2
  • item 3

Numbered list

You can make a numbered list like this

  1. First thing I want to say
  2. Second thing I want to say
  3. Third thing I want to say
<<<<<<< HEAD

Politics and Vaccinations

Tracking Statewide Vaccinations

=======

Politics and Vaccinations

Tracking Statewide Vaccinations

>>>>>>> 77298c790997af7699687a8a24f6ecc08ea5a8ef